<template>
<h3>{{title}}</h3>
    <el-form :model="ruleForm" :rules="rules" label-width="200px" class="demo-ruleForm">
 <el-form-item label="活动预热期（c）">
    <el-date-picker
      v-model="value1"
      type="daterange"
      align="left"
      start-placeholder="请选择日期时间"
      end-placeholder="请选择日期时间"
      :default-value="[new Date(2010, 9, 1), new Date(2010, 10, 1)]">
    </el-date-picker>
  </el-form-item>
  <el-form-item label="活动时间（c）" required>
    <el-date-picker
      v-model="value2"
      type="datetimerange"
      start-placeholder="开始日期"
      end-placeholder="结束日期"
      :default-time="new Date(2000, 1, 1, 12, 0, 0)"
      >
    </el-date-picker>
  </el-form-item>
 
</el-form>
  
  
</template>
<script>
import {ref} from 'vue'
  export default {
    props:['title'],
     setup() {
      
      return {
        value1:ref(''),
        value2:ref([new Date(2020, 4, 12, 11, 20,52), new Date(2020, 4, 20, 11, 20,52)]),
        rules:[
            { type: 'date', required: true, message: '请选择时间日期', trigger: 'change' }
          ],
      }
      
    },
    
    
  };
</script>
